CoglPipeline *
_st_create_shadow_pipeline (StShadow *shadow_spec,
- CoglTexture *src_texture)
+ CoglTexture *src_texture,
+ float resource_scale)
{
ClutterBackend *backend = clutter_get_default_backend ();
CoglContext *ctx = clutter_backend_get_cogl_context (backend);
rowstride_in, pixels_in);
pixels_out = blur_pixels (pixels_in, width_in, height_in, rowstride_in,
- shadow_spec->blur,
+ shadow_spec->blur * resource_scale,
&width_out, &height_out, &rowstride_out);
g_free (pixels_in);
if (texture &&
cogl_texture_get_width (texture) == width &&
cogl_texture_get_height (texture) == height)
- shadow_pipeline = _st_create_shadow_pipeline (shadow_spec, texture);
+ shadow_pipeline = _st_create_shadow_pipeline (shadow_spec, texture,
+ resource_scale);
}
if (shadow_pipeline == NULL)
cogl_object_unref (fb);
- shadow_pipeline = _st_create_shadow_pipeline (shadow_spec, buffer);
+ shadow_pipeline = _st_create_shadow_pipeline (shadow_spec, buffer,
+ resource_scale);
cogl_object_unref (buffer);
}
/* Helper for widgets which need to draw additional shadows */
CoglPipeline * _st_create_shadow_pipeline (StShadow *shadow_spec,
- CoglTexture *src_texture);
+ CoglTexture *src_texture,
+ float resource_scale);
CoglPipeline * _st_create_shadow_pipeline_from_actor (StShadow *shadow_spec,
ClutterActor *actor);
cairo_pattern_t *_st_create_shadow_cairo_pattern (StShadow *shadow_spec,
if (background_image_shadow_spec)
{
node->background_shadow_pipeline = _st_create_shadow_pipeline (background_image_shadow_spec,
- node->background_texture);
+ node->background_texture,
+ resource_scale);
}
}
{
if (st_theme_node_load_border_image (node))
state->box_shadow_pipeline = _st_create_shadow_pipeline (box_shadow_spec,
- node->border_slices_texture);
+ node->border_slices_texture,
+ state->resource_scale);
else if (state->prerendered_texture != NULL)
state->box_shadow_pipeline = _st_create_shadow_pipeline (box_shadow_spec,
- state->prerendered_texture);
+ state->prerendered_texture,
+ state->resource_scale);
else if (node->background_color.alpha > 0 || has_border)
st_theme_node_prerender_shadow (state);
}
if (had_box_shadow)
state->box_shadow_pipeline = _st_create_shadow_pipeline (box_shadow_spec,
- state->prerendered_texture);
+ state->prerendered_texture,
+ state->resource_scale);
}
static void
st_theme_node_paint_borders (state, offscreen, &box, 0xFF);
state->box_shadow_pipeline = _st_create_shadow_pipeline (st_theme_node_get_box_shadow (node),
- buffer);
+ buffer, state->resource_scale);
}
else
{